aboutsummaryrefslogtreecommitdiffstats
path: root/src/routes/(app)/funds/[id]/sweep
diff options
context:
space:
mode:
Diffstat (limited to 'src/routes/(app)/funds/[id]/sweep')
-rw-r--r--src/routes/(app)/funds/[id]/sweep/+page.server.js14
-rw-r--r--src/routes/(app)/funds/[id]/sweep/+page.svelte37
2 files changed, 0 insertions, 51 deletions
diff --git a/src/routes/(app)/funds/[id]/sweep/+page.server.js b/src/routes/(app)/funds/[id]/sweep/+page.server.js
deleted file mode 100644
index 9fd244a3..00000000
--- a/src/routes/(app)/funds/[id]/sweep/+page.server.js
+++ /dev/null
@@ -1,14 +0,0 @@
-import { get, auth, post } from '$lib/utils';
-import { redirect } from '@sveltejs/kit';
-
-export async function load({ cookies, params, parent }) {
- let { user } = await parent();
- let { id } = params;
- let { amount } = await get(`/fund/${id}`);
-
-
- if (!amount) throw redirect(307, `/fund/${id}`);
- if (!user) throw redirect(307, `/register?redirect=/fund/${id}/sweep`);
- await post('/take', { amount, id }, auth(cookies));
- return { amount, id };
-}
diff --git a/src/routes/(app)/funds/[id]/sweep/+page.svelte b/src/routes/(app)/funds/[id]/sweep/+page.svelte
deleted file mode 100644
index 64bed4dd..00000000
--- a/src/routes/(app)/funds/[id]/sweep/+page.svelte
+++ /dev/null
@@ -1,37 +0,0 @@
-<script>
- import { scale } from 'svelte/transition';
- import { fiat, f, s } from '$lib/utils';
- import { Icon } from '$comp';
- import { t } from '$lib/translations';
-
- export let data;
-
- let { amount, id, user, rates } = data;
- let { currency } = user;
- $: rate = rates[currency];
-</script>
-
-<div class="container px-4 max-w-xl mx-auto mt-10 space-y-5 text-center">
- <div class="w-full flex">
- <a href="/" class="mx-auto">
- <Icon icon="logo" />
- </a>
- </div>
-
- <div class="flex w-full py-5 max-w-[200px] mx-auto" in:scale={{ start: 0.5 }}>
- <Icon icon="check" style="mx-auto" />
- </div>
- <h1 class="text-3xl md:text-4xl font-bold mb-6">{$t('payments.fundsClaimed')}</h1>
- <h2 class="text-2xl md:text-3xl font-semibold">
- {f(fiat(amount, rate), currency)}
- </h2>
- <h3 class="text-secondary md:text-lg mb-6 mt-1">
- ⚡️{s(amount)}
- </h3>
-</div>
-
-<a href={`/${user.username}/payments`}>
- <div class="opacity-0 w-screen h-screen fixed top-0 left-0 z-50" />
-</a>
-
-<div class="fixed bottom-10 w-full text-center">{$t('payments.tapAnywhere')}</div>